<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <!-- action提交到服务端地址 method提交方式 -->
    <form action="" method="">
        <input type="text" name="username" />
        <input type="password" name="pwd" />
        <input type="submit" name="login" />
    </form>
</body>
<script>
    // fetch(请求地址 配置项)
    fetch("http://192.168.174.166:3000/", { method: "POST" })
        .then(res => res.text())
        .then(res => {
            console.log(res)
        })

</script>

</html>